﻿<section class="mainbar">
    <section class="matter">
        <div class="container">
            <div class="row">
                <div class="widget wblue">
                    <div data-cc-widget-header title="{{vm.title}}"></div>
                    <div class="widget-content user">
                        <!--<pre>{{vm.maa.data | json}}</pre>-->
                        <input data-ng-model="vm.filter.name" placeholder="Find Avengers by name"/>
                        <button class="btn btn-info" ng-click="vm.refresh()">Refresh with New and Modifed Data</button>
                        <cc-note message="vm.msg.bindOnce" dismissible="true"></cc-note>
                        <table class="table table-condensed table-striped">
                            <thead>
                            <tr>
                                <th></th>
                                <th>ng-model (2 way)</th>
                                <th>ng-bind (1 way)</th>
                                <th>bind once (1 time)</th>
                            </tr>
                            </thead>
                            <tbody>
                            <tr data-ng-repeat="c in vm.maa | filter:vm.filter track by c.id">
                                <td><img
                                        ng-src="{{c.thumbnail.path}}.{{c.thumbnail.extension}}"
                                        class="avenger-thumb img-rounded"/></td>
                                <!--<td><span class="avenger-name">{{c.name}}</span></td>-->
                                <td><input class="avenger-name" ng-model="c.name"/></td>
                                <td>{{c.name}}</td>
                                <td>{{::c.name}}</td>
                            </tr>
                            </tbody>
                        </table>
                    </div>
                    <div data-cc-widget-header title="{{vm.title}} - Array"></div>
                    <div class="widget-content user">
                        <cc-note message="vm.msg.arrayBindOnce" dismissible="true"></cc-note>
                        <ol>
                            <li ng-repeat="item in ::vm.maa track by item.id">{{item.name}}</li>
                        </ol>
                        <button ng-click="vm.addAvenger()" class="btn btn-info">Add Avenger</button>
                    </div>
                    <div class="widget-foot">
                        <div class="clearfix"></div>
                    </div>
                </div>
            </div>
        </div>
    </section>
</section>
